package com.xmotor.test_JavaAPI;

import java.util.Arrays;

/**
 * @Description 测试
 * @Author Dang Xianyue
 * @Date 2020-08-09 15:05
 * @Version 1.0
 */
public class TestArrayForEach {
    public static void main(String[] args) {
        String[] strArr = new String[]{"a***","b**","c**","d*"};
        //Arrays.stream(strArr).map(s -> s = s+"1");
        for (int i = 0; i < strArr.length; i++) {
            strArr[i] = strArr[i].replace("**","*");
        }

        System.out.println(Arrays.toString(strArr));


    }
}
